package com.example.deploysinggle.test1.common.redis;

import com.fasterxml.jackson.core.type.TypeReference;

import java.util.List;

/**
 * @author Administrator
 * @version 1.0
 * @description: TODO
 * @date 2024/12/15 19:32
 */
public interface CacheService
{
    void set(String key, Object value, Long time);

    void set(String key, Object value);

    String get(String key);

    <T> T get(String key, Class<T> clazz);

    Boolean hasKey(String key);

    Long increment(String key, long delta);

    <T> List<T> getList(String key, TypeReference<List<T>> typeReference);
}